<?php
namespace app\common\model;
use app\common\model\BaseModel;

/**
 * 
 */
class AccountLogModel extends BaseModel
{ 
	public function add($data)
	{
		$res=$this->isUpdate(false)->allowField(true)->save($data);
		if ($res) {
			return 1;
		}else{
			$this->error='添加失败';
			return 0;
		}
	} 

	public function edit($data)
	{
		$group=$this->find($data['id']);
		$res=$group->isUpdate(true)->allowField(true)->save($data);
		if ($res) {
			return 1;
		}else{
			
		}
	}
}